﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Windows;
using QuickTweet.Common.Services;
using QuickTweet.Views;
using QuickTweet.Common;

namespace QuickTweet
{
    /// <summary>
    /// Interaction logic for App.xaml
    /// </summary>
    public partial class App : Application
    {
        private void Application_Startup(object sender, StartupEventArgs e)
        {
            //Registra i servizi utilizzati dall'applicazione.
            ServiceLocator.RegisterView(ViewNames.AboutView, typeof(AboutView));
            ServiceLocator.RegisterView(ViewNames.EditAccountView, typeof(EditAccountView));
            ServiceLocator.RegisterConfirmFunction(ConfirmFunctionNames.ConfirmAccountDelete,
                (message, action) => DialogService.Confirm("QuickTweet", message, null, action));
        }
    }
}
